import request from "./request.js"
//微信登录
export function getMemberInfo(params) {
	return request("/api/member/getMemberInfo", "GET", params)
}
//微信登录
export function newgetOpenId(params) {
	return request("/api/member/wxAutoLogin", "POST", params)
}

//关注获取
export function memberTags(params) {
	return request(`/api/comm/loadDict/member_tags`, "GET", params)
}

//关注添加
export function modifyMemberInfo(params) {
	return request('/api/member/modifyMemberInfo', "POST", params)
}
//用户标签
export function imemberTags(params) {
	return request('/api/member/memberTags', "GET", params)
}

//首页最新
export function indexInfList(params) {
	return request("/api/information/indexInfList/" + params.status + '?pageNo=' + params.pageNo, "GET", params)
}
//首页最新
export function newsa(params) {
	return request("/api/information/indexInfList/CATEGORY", "GET", params)
}
// 官方直推
export function OFFICIAL(params) {
	return request("/api/information/indexInfList/OFFICIAL", "GET", params)
}
//会员商品
export function goodList(params) {
	return request("/api/contactsGoods/goodList", "GET", params)
}
//详情
export function details(params) {
	return request("/api/information/details/" + params.id, "GET")
}
//发布
export function saveInformation(params) {
	return request("/api/information/saveInformation/SAVE", "POST", params)
}
//修改
export function saveInformationUPDATE(params) {
	return request("/api/information/saveInformation/UPDATE", "POST", params)
}

//修改帖子状态
export function modifyInformationStatus(params) {
	//1 草稿 2 提交 3 下线 
	return request("/api/information/modifyInformationStatus/" + params.infId + '/' + params.publishStatus, "PUT")
}
//我的发布
export function myPublish(params) {
	return request("/api/information/myPublish", "GET", params)
}

//我的会员
export function myMember(params) {
	return request("/api/member/myMember", "GET", params)
}

//字典
export function loadDict(params) {
	return request("/api/comm/loadDict/" + params, "GET", params)
}
//下单
export function takeOrder(params) {
	return request("/api/order/takeOrder/" + params, "POST")
}
//订单支付
export function orderPay(params) {
	return request("/api/order/orderPay", "POST", params)
}
//帖子付费
export function memberVipPay(params) {
	return request("/api/order/memberVipPay", "POST", params)
}
//收藏信息
export function infCollection(params) {
	return request("/api/information/infCollection/" + params, "GET", params)
}

//我的收藏
export function myCollection(params) {
	return request("/api/information/myCollection", "GET", params)
}

//cdk兑换
export function cdk(params) {
	return request("/api/member/cdk/" + params, "GET")
}

//申请加盟
export function joinUs(params) {
	return request("/api/member/joinUs", "POST", params)
}

//生成二维码赋能 二维码-1
export function getQRCodes(params) {
	return request("/api/pageTemplate/add", "POST-x-www-form-urlencoded", params)
}
//生成二维码赋能 二维码-2
export function pageTemplate(params) {
	return request("/api/QRCode/getQRCode", "GET", params)
}

//赋能记录
export function pageTemplateList(params) {
	return request("/api/pageTemplate/page", "GET", params)
}

//验证码
export function sendSms(params) {
	return request("/api/comm/sendSms", "POST", params)
}

//APP登录
export function checkSmsCode(params) {
	return request("/api/member/appLogin", "POST", params)
}

//APPbanner获取
export function bannerList(params) {
	return request("/api/comm/bannerList", "GET", params)
}


//讯息浏览
export function viewerAdd(params) {
	return request("/api/information/viewerAdd/" + params, "GET", params)
}
//讯息浏览
export function shengpage(params) {
	return request("/api/category/page", "GET", params)
}
export function CATEGORY(params) {
	return request("/api/category/page/CATEGORY", "GET", )
}
//全部的分类信息
export function allType(params) {
	return request("/api/story/allType", "GET", params)
}
//根据分类信息查询故事
export function storyByType(params) {
	return request("/api/story/storyByType", "GET", params)
}
//我的推荐页面
export function myRecommendCode(params) {
	return request("/api/recommend/myRecommendCode", "GET", params)
}
//我的推荐
export function myRecommend(params) {
	return request("/api/recommend/myRecommend", "GET", params)
}

//根据邀请码获取用户信息
export function getUserInfoByRecCode(params) {
	return request("/api/recommend/getUserInfoByRecCode/" + params, "GET")
}
//绑定推荐
export function bindRecommendShip(params) {
	return request("/api/recommend/bindRecommendShip/" + params, "PUT")
}
//我的收益
export function myIncome(params) {
	return request("/api/memberIncome/myIncome", "GET", params)
}
//申请提现
export function applyTake(params) {
	return request("/api/memberIncome/applyTake", "GET", params)
}
//提现记录
export function takeHis(params) {
	return request("/api/memberIncome/takeHis", "GET", params)
}

//修改提现信息
export function modifyTakeInfo(params) {
	return request("/api/memberIncome/modifyTakeInfo", "PUT", params)
}
//付费获取联系方式
export function getContact(params) {
	return request("/api/information/getContact/" + params, "GET", params)
}
//收益记录
export function getIncome(params) {
	return request("/api/member/getIncome", "GET", params)
}
//提现
export function addWithdraw(params) {
	return request("/api/member/addWithdraw", "POST", params)
}

//公告列表
export function contentList(params) {
	return request("/api/information/contentList", "GET", params)
}
//取消收藏
export function infClearCollection(params) {
	return request("/api/information/infClearCollection/" + params, "GET", params)
}
//浏览记录
export function informationHis(params) {
	return request("/api/informationHis/page", "GET", params)
}
//add浏览记录
export function addHis(params) {
	return request("/api/informationHis/addHis", "POST", params)
}